// function indetify (context){
// return context.name.toUpperCase()//把name的值转换成大写
// }
// function speak (context){
//     var greeting = "Hello, I'm "+indetify(context)
//     console.log(greeting)
// }

function indetify() {
    return this.name.toUpperCase()//把name的值转换成大写
}
function speak() {
    var greeting = "Hello, I'm " + indetify.call(this)//把indetify作用域掰到this作用域里面
    console.log(greeting)
}

var me = {
    name: 'wn'
}
var you = {
    name: 'yj'
}
// let result = indetify.call(me)
// let result2 = indetify.call(you)
// console.log(result);//WN
// console.log(result2);//YJ

//speak(me);
speak.call(me)//speck当前作用域掰到me作用域里面